<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page contentType="text/html;utf-8" pageEncoding="UTF-8" isELIgnored="false" %>

<!doctype html>
<html lang="cn">
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>userList</title>
</head>
<body>
<a href="${pageContext.request.contextPath}/add.jsp">添加</a>
<table>
    <c:forEach items="${requestScope.userList}" var="user">
        <tr>
            <td></td>
            <td>${user.name}</td>
            <td>${user.age}</td>
            <td>${user.username}</td>
            <td>${user.password}</td>
            <td><a href="${pageContext.request.contextPath}/user/findOne?id=${user.id}">编辑</a></td>
            <td><a href="${pageContext.request.contextPath}/user/deleteOne?id=${user.id}">删除</a></td>
        </tr>
    </c:forEach>
</table>
</body>
</html>
